﻿<UserControl
    x:Class="ExampleApp.Views.Validation.BasicValidationView"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="using:ExampleApp.Views.Validation"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
    xmlns:View="using:StyleMVVM.View"
    View:ViewModel.Name="BasicValidationViewModel"
    mc:Ignorable="d"
    d:DesignHeight="300"
    d:DesignWidth="400">
    <Grid>
        <TextBlock HorizontalAlignment="Left" Margin="40,46,0,0" TextWrapping="Wrap" Text="Prefix" VerticalAlignment="Top"/>
        <ComboBox Template="{StaticResource ValidationComboBox}" SelectedItem="{Binding Prefix,Mode=TwoWay}" 
            View:Validation.Property="Prefix"      
            ItemsSource="{Binding Prefixes}"
            HorizontalAlignment="Left" Margin="123,36,0,0" VerticalAlignment="Top" Width="267"/>

        <TextBlock HorizontalAlignment="Left" Margin="40,82,0,0" TextWrapping="Wrap" Text="First Name" VerticalAlignment="Top"/>
        <TextBox Text="{Binding FirstName,Mode=TwoWay}" 
                 View:Validation.Property="FirstName" 
                 Template="{StaticResource ValidationTextbox}"
                 HorizontalAlignment="Left" Margin="123,73,0,0" TextWrapping="Wrap" VerticalAlignment="Top" Width="267"/>

        <TextBlock HorizontalAlignment="Left" Margin="40,119,0,0" TextWrapping="Wrap" Text="Middle Name" VerticalAlignment="Top"/>
        <TextBox Text="{Binding MiddleName,Mode=TwoWay}" 
        	View:Validation.Property="MiddleName" 
        	Template="{StaticResource ValidationTextbox}"
        	HorizontalAlignment="Left" Margin="123,110,0,0" TextWrapping="Wrap" VerticalAlignment="Top" Width="267"/>
        
        <TextBlock HorizontalAlignment="Left" Margin="40,156,0,0" TextWrapping="Wrap" Text="Last Name" VerticalAlignment="Top"/>
        <TextBox Text="{Binding LastName, Mode=TwoWay}" 
        	View:Validation.Property="LastName" 
        	Template="{StaticResource ValidationTextbox}"
        	HorizontalAlignment="Left" Margin="123,147,0,0" TextWrapping="Wrap" VerticalAlignment="Top" Width="267"/>
        
        <TextBlock HorizontalAlignment="Left" Margin="40,194,0,0" TextWrapping="Wrap" Text="Email Address" VerticalAlignment="Top"/>
        <TextBox Text="{Binding EmailAddress,Mode=TwoWay}" 
        	View:Validation.Property="EmailAddress" 
        	Template="{StaticResource ValidationTextbox}"
        	HorizontalAlignment="Left" Margin="123,184,0,0" TextWrapping="Wrap" VerticalAlignment="Top" Width="267"/>
        
        <Button Content="Save" Command="{Binding SaveCommand}" HorizontalAlignment="Left" Margin="302,230,0,0" VerticalAlignment="Top"/>


    </Grid>
</UserControl>
